Print a more sensible error when the user's edge preview token is expired#6472
Print a more sensible error when the user's edge preview token is expired#6472kflansburg wants to merge 2 commits intocloudflare:mainfrom
Conversation
7a1c20a to
fcbcb27
Compare
fcbcb27 to
c4a81bf
Compare
kentonv
left a comment
There was a problem hiding this comment.
I think this is the same issue as: cloudflare/workers-sdk#12901
If fixed in wrangler, then the error message here should become irrelevant?
@penalosa did some work to fix it there though it seems like it's still broken for me unfortunately.
| // preview token has expired (e.g. during `wrangler dev`). | ||
| if (content.includes('error code: 1031')) { | ||
| return new InferenceUpstreamError( | ||
| `${content} (your API token may have expired — try running \`wrangler login\` to obtain a fresh token and restart your dev server)` |
There was a problem hiding this comment.
I don't think running wrangler login again is required. Simply restarting wrangler solves the problem.
Yes, thank you. @thatsKevinJain is looking in to resolving the issue in cloudflare/workers-sdk#12901 |
No description provided.